package springmvc.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

@Controller
public class firstController {

    @RequestMapping(value = "/test")
    public String test(){
        return "ok";
    }


//    @RequestMapping(value = "/test")
//    public String hehe(){
//        return "ok";
//
//    }


//    @RequestMapping(value = "/hei")
//    public String  hh(){
//        return "hei";
//    }

    @RequestMapping(value = "/login/{a}/{b}")
    public String A(
            @PathVariable("a")
            String a,
            @PathVariable("b")
            String b){
                System.out.println(a+" "+b);
                return "ok";
    }

    @RequestMapping(value = "/aaa",method = RequestMethod.POST)
    public String login(){
        System.out.println("处理登录的业务....");
        return "ok";
    }

}
